//vect1.cpp -- introducing the vector template
#include <iostream>
#include <vector>
#include <string>

const int NUM = 5;
int main()
{
	using std::vector;
	using std::string;
	using std::cin;
	using std::cout;
	using std::endl;

	vector<int> ratings(NUM);
	vector<string> titles(NUM);
	cout<<"you will do exactly as told,you will enter\n"<<NUM<<"book titles and your ratings(0-10).\n"<<endl;
	int i;
	for (i=0;i<NUM;++i)
	{
		cout<<"enter title #"<<i+1<<":";
		getline(cin,titles[i]);
		cout<<"enter your rating(0-10):";
		cin>>ratings[i];
		cin.get();
	}
	cout<<"thank you ,you enter the following:\n"<<"rating\tBOOK\n";
	for(i=0;i<NUM;i++)
	{
		cout<<ratings[i]<<"\t"<<titles[i]<<endl;
	}
}

